#include "SMPPBroadcastMessageClass.hpp"

using namespace smpp::pdu;

BroadcastMessageClass::BroadcastMessageClass(const quint8 nValue):
TLV(TLVtags::TAG_BROADCAST_MESSAGE_CLASS,1),_Value(nValue){}

BroadcastMessageClass::BroadcastMessageClass(
const BroadcastMessageClass &nBroadcastMessageClass):
TLV(nBroadcastMessageClass),_Value(nBroadcastMessageClass.getValue()){}

bool BroadcastMessageClass::operator ==(
	const BroadcastMessageClass &nBroadcastMessageClass) const{
	return (TLV::operator == (nBroadcastMessageClass) && 
			_Value == nBroadcastMessageClass.getValue());
}

bool BroadcastMessageClass::operator !=(
	const BroadcastMessageClass &nBroadcastMessageClass) const{
		return !this->operator == (nBroadcastMessageClass);
}

BroadcastMessageClass &BroadcastMessageClass::operator = (
	const BroadcastMessageClass &nBroadcastMessageClass){
	if(*this == nBroadcastMessageClass)
		return *this;
	TLV::operator = (nBroadcastMessageClass);
	_Value = nBroadcastMessageClass.getValue();
	return *this;
}

void BroadcastMessageClass::setValue(const quint8 nValue){
	_Value = nValue;
}

const quint8 BroadcastMessageClass::getValue() const{
	return _Value;
}
